﻿//  -------------------- iSharePoint -------------------- //
// 
//  Company:	IT Complex, LLC
//  Project:	Smart.Common
//  File name:	SecurityContext.cs
//  Developer:	Solomatov Igor
//  Created:	15.04.2012
// 
//  -------------------- iSharePoint -------------------- //

using System;
using System.Collections.Generic;

namespace Smart.Common.Security
{
	/// <summary>
	/// Security context
	/// </summary>
	public class SecurityContext
	{
		public Guid SiteID { get; set; }

		/// <summary>
		/// Security service type name
		/// </summary>
		public string ServiceName { get; set; }

		/// <summary>
		/// Security service
		/// </summary>
		public ISecurityService Service { get; set; }

		/// <summary>
		/// Context-defined values
		/// </summary>
		public Dictionary<string, object> Values { get; set; }

		/// <summary>
		/// Security context
		/// </summary>
		public SecurityContext(string serviceName)
		{
			ServiceName = serviceName;

			Values = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
		}
	}
}